package com.bwie.controller;

import com.bwie.mapper.TbGoodsMapper;
import com.bwie.pojo.TbGoods;
import com.bwie.service.TbGoodsService;
import com.bwie.utils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/shop/image")
public class ImagesController {

    @Autowired
    TbGoodsService tbGoodsService;


    @PostMapping("/getGoodsList")
    public Result getGoodsList(){

        return tbGoodsService.getGoodsList();
    }

    @PostMapping("/saveGoods")
    public Result saveGoods(@RequestBody TbGoods tbGoods){
        return tbGoodsService.saveGoods(tbGoods);
    }



}
